package com.group.transaction.mapper;

import com.group.transaction.model.ResultJson;
import org.apache.ibatis.annotations.Param;

import com.group.transaction.domain.Logistics;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface LogisticsMapper extends Mapper<Logistics> {

    /**
     * 查询部门
     *
     * @param logistics
     * @return
     */
    List<Logistics> queryLogisticsData(Logistics logistics);

    /**
     * 查询部门总数
     *
     * @param logistics
     * @return
     */
    Integer queryLogisticsDataTotal(Logistics logistics);

    /**
     * 通过 用户id 获取 物流单数量
     *
     * @param userId 用户id
     * @return 物流单数量
     */
    Integer findCountByUserId(@Param("userId") Long userId);

    /**
     * 通过 用户id 获取 物流单
     *
     * @param userId 用户id
     * @return 物流单
     */
    List<Logistics> findAllByUserId(@Param("userId") Long userId);
    /**
     *
     *
     * @param logistics
     * @return
     */
    Integer updateLogisticsData(Logistics logistics);
    /**
     * 根据物流id查询物流信息
     * @param
     * @return
     */
    Logistics queryLogisticsDataById(Long id);

}